/**
 * Alipay.com Inc.
 * Copyright (c) 2004-2012 All Rights Reserved.
 */
package com.pingan.mobilegw.mobileservice.invoke;

import com.pingan.mobilegw.adapterservice.model.ToString;

import java.lang.reflect.Method;
import java.lang.reflect.Type;

/**
 * 记录Method相关信息，在处理方法调用时能够利用这些信息加速方法的调用 
 * 
 * @author shuai.ls
 * @version $Id: MethodInfo.java, v 0.1 2013-5-14 下午3:36:42 jiadao Exp $
 */
public class MethodInfo extends ToString {

    /** serialVersionUID */
    private static final long serialVersionUID = 1855104662889470439L;

    /** 普通参数个数 */
    private int               paramCount       = 0;

    /** 各个参数类型 */
    private Type[]            paramType        = null;

    /** 服务对象 */
    private Object            target           = null;

    /** 方法对象 */
    private Method            method           = null;

    /**
     * Getter method for property <tt>paramCount</tt>.
     * 
     * @return property value of paramCount
     */
    public int getParamCount() {
        return paramCount;
    }

    /**
     * Setter method for property <tt>paramCount</tt>.
     * 
     * @param paramCount value to be assigned to property paramCount
     */
    public void setParamCount(int paramCount) {
        this.paramCount = paramCount;
    }

    /**
     * Getter method for property <tt>target</tt>.
     * 
     * @return property value of target
     */
    public Object getTarget() {
        return target;
    }

    /**
     * Setter method for property <tt>target</tt>.
     * 
     * @param target value to be assigned to property target
     */
    public void setTarget(Object target) {
        this.target = target;
    }

    /**
     * Getter method for property <tt>method</tt>.
     * 
     * @return property value of method
     */
    public Method getMethod() {
        return method;
    }

    /**
     * Setter method for property <tt>method</tt>.
     * 
     * @param method value to be assigned to property method
     */
    public void setMethod(Method method) {
        this.method = method;
    }

    /**
     * Getter method for property <tt>paramType</tt>.
     * 
     * @return property value of paramType
     */
    public Type[] getParamType() {
        return paramType;
    }

    /**
     * Setter method for property <tt>paramType</tt>.
     * 
     * @param paramType value to be assigned to property paramType
     */
    public void setParamType(Type[] paramType) {
        this.paramType = paramType;
    }

}
